#ifndef FT_REFINEMENT
#define FT_REFINEMENT

#define SPECIALIZATION_LANGUAGE_AUTODETECT	-1
#define SPECIALIZATION_LANGUAGE_L0	0
#define SPECIALIZATION_LANGUAGE_L1P	1
#define SPECIALIZATION_LANGUAGE_L1S	2
#define SPECIALIZATION_LANGUAGE_L2	3


/* 
	Only those terms appearing in the domain_model (plus integers, floats and strings) will be considered as valid
	domain specializations.
 */ 

/* These operators, generate the refinements that subsume all the objects in "objects": */ 
List<FeatureTerm> *DSpecializationL0(FeatureTerm *ft,List<FeatureTerm> *objects,int max_depth,Ontology *ontology,FTKBase *domain_model);
List<FeatureTerm> *DSpecializationL1P(FeatureTerm *ft,List<FeatureTerm> *objects,int max_depth,Ontology *ontology,FTKBase *domain_model);
List<FeatureTerm> *DSpecializationL1S(FeatureTerm *ft,List<FeatureTerm> *objects,List<Path> *set_paths,Ontology *ontology,int max_depth,FTKBase *domain_model);
List<FeatureTerm> *DSpecializationL2(FeatureTerm *ft,List<FeatureTerm> *objects,List<Path> *set_paths,Ontology *ontology,int max_depth,FTKBase *domain_model);

List<FeatureTerm> *DSpecialization(FeatureTerm *ft,List<FeatureTerm> *objects,Ontology *ontology,FTKBase *domain_model,int max_depth,List<Path> *set_paths,bool sort,bool feature,bool equality,bool sets,bool costants);

/* These second set of operators, generate the refinements that subsume at least one of the objects in "objects": */ 
List<FeatureTerm> *DSpecializationL0_b(FeatureTerm *ft,List<FeatureTerm> *objects,Ontology *ontology,FTKBase *domain_model);
List<FeatureTerm> *DSpecializationL1P_b(FeatureTerm *ft,List<FeatureTerm> *objects,Ontology *ontology,FTKBase *domain_model);
List<FeatureTerm> *DSpecializationL1S_b(FeatureTerm *ft,List<FeatureTerm> *objects,List<Path> *set_paths,Ontology *ontology,FTKBase *domain_model);
List<FeatureTerm> *DSpecializationL2_b(FeatureTerm *ft,List<FeatureTerm> *objects,List<Path> *set_paths,Ontology *ontology,FTKBase *domain_model);

List<FeatureTerm> *DSpecialization_b(FeatureTerm *ft,List<FeatureTerm> *objects,Ontology *ontology,FTKBase *domain_model,List<Path> *set_paths,bool sort,bool feature,bool equality,bool sets,bool costants);


#endif
